import { createRouter, createWebHashHistory } from 'vue-router';
import BasicLayout from '@/layout/BasicLayout.vue';

const routes = [
  {
    // 布局页面
    path: '/',
    component: BasicLayout,
    redirect: '/home',
    children: [
      // 业务页面放在该级目录下
      {
        path: '/home',
        name: 'home',
        component: () => import('@/views/Home.vue'),
      },
    ],
  },
];

export const router = createRouter({
  history: createWebHashHistory(),
  routes,
});
